package com.mrdeer.user.convert;

import com.mrdeer.user.api.dto.menu.MenuDTO;
import com.mrdeer.user.api.entity.ResourceMenu;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * @author ：xie jianchu
 * @date ：Created in 2020/9/7 0007 17:44
 */
@Mapper
public interface ResourceMenuConvert {

    ResourceMenuConvert INSTANCE = Mappers.getMapper(ResourceMenuConvert.class);

    MenuDTO entity2Dto(ResourceMenu entity);

    ResourceMenu dto2Entity(MenuDTO dto);

    List<MenuDTO> entityList2Dto(List<ResourceMenu> resourceMenu);

    List<ResourceMenu> dtoList2Entity(List<MenuDTO> menuDTO);
}
